//
// Created by pzw on 24-3-19.
//

#include "MaxMinValue.h"

void MaxMinValue::std_max_min_value(std::string s) {
    using namespace std;
    auto p = minmax_element(
            s.begin(), s.end(),
            [](char c1, char c2) {
                return toupper(c1) < toupper(c2);
            }
    );
    cout << "min = " << *(p.first) << ", max = " << *(p.second) << endl;
}

int MaxMinValue_main() {
    std::string s = "Large_Hadron_Collider";
    MaxMinValue::std_max_min_value(s);
    return 0;
}